package com.naja.auth2server.entity;

import java.util.Date;

import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;

import java.io.Serializable;
import lombok.ToString;
import lombok.Data;

/**
 * 三方用户关系表(UserThirdRelate)表实体类
 *
 * @author EasyCode
 * @since 2024-01-02 14:53:50
 */
@ToString
@Data
public class UserThirdRelate extends Model<UserThirdRelate> {

    //主键id
    private Long id;

    //用户id
    private Long userId;

    //第三方用户id
    private Long thirdId;

    //第三方类型:微信 github 等
    private String thirdType;

    //创建时间
    private Date createTime;

    //创建者
    private Long createBy;

    @TableField(fill = FieldFill.UPDATE)//更新时间
    private Date updateTime;

    //更新者
    private Long updateBy;

    //是否删除 0 有效 1删除
    private Integer deleted;

    //备注
    private String remark;

    /**
     * 获取主键值
     *
     * @return 主键值
     */
    @Override
    public Serializable pkVal() {
        return this.id;
    }

}

